#!/usr/bin/env node

async function logger(ctx,next){
  const start=Date.now();
  await next();
  const end=Date.now();
  const cost=end-start;
  console.log(`${ctx.method} ${ctx.path} - ${cost}ms`);
 }

module.exports=logger;

